package com.xinling.modules.chat.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.HashMap;
import java.util.Map;

@RestController
@RequestMapping("/ws")
public class WebSocketController {

    @GetMapping("/info")
    public Map<String, Object> getWebSocketInfo() {
        Map<String, Object> info = new HashMap<>();
        info.put("websocket", true);
        info.put("origins", new String[]{"*"});
        info.put("cookie_needed", false);
        info.put("entropy", System.currentTimeMillis());
        return info;
    }
} 